<template>
	<view>
		<view v-if="StudentStatusInfo.length!=0">
			<view v-if="StudentStatusInfo.length!=0" v-for="(value,key) in StudentStatusInfo" :key="key" @click="gotoInfo(key)">
				<view v-if="value.status==1">
					<statusItem :ColorType="ColorType" :StudentFindPass="value"></statusItem>
				</view>
			</view>
		</view>
		<view v-else>
			<nodataView></nodataView>
		</view>
	</view>
</template>

<script>
	import statusItem from './statusItemChild/statusItem.vue'
	import nodataView from '@/components/nodataView/nodataView.vue'
	// import {
	// 	// getTest,
	// 	getStudentFindPass
	// } from '@/api/status/service.js';

	// import {
	// 	getStudentStatusInfoByStatusAndTid
	// } from '@/api/status/service.js';


	export default {
		props: {
			show: {
				type: Boolean,
				default: false
			},
			xmId: {
				type: Number,
				default: 0
			},
			StudentStatusInfo: {
				type: Array,
				default: []

			}

		},
		data() {
			return {
				ColorType: 1,
				// StudentFindPass:'',
				// id :'1',
				// StudentStatusInfo:[],
				// tId:0
			}
		},
		components: {
			nodataView,
			statusItem,
		},
		created() {
			console.log("created");
			// this.tId = uni.getStorageSync("Teaid");
			// this.loadData();

		},

		methods: {
			gotoInfo(res) {
				console.log(res)
			},
			/* getData(id){
				getStudentFindPass(id)
				.then(res=>{
					this.StudentFindPass = res.data;
					console.log(res.data)
				}).catch(res=>{
					console.log(res)
				})
			},
			 */
			// loadData() {
			// 	console.log("aaaa",this.tId);
			// 	getStudentStatusInfoByStatusAndTid(this.tId, 1)
			// 		.then(res => {
			// 			this.StudentStatusInfo = res.data.list
			// 			console.log(this.StudentStatusInfo)
			// 			console.log(res)
			// 		}).catch(res => {
			// 			console.log(res)
			// 		})
			// }
		}
	}
</script>

<style>

</style>
